fix: add 'run' subcommand to Dockerfile CMD after clap migration#335
Merged
thepagent merged 1 commit intoopenabdev:mainfrom Apr 14, 2026
Merged
Conversation
After openabdev#191 added clap CLI with subcommands, the Dockerfiles still passed the config path as a positional argument, which clap interprets as an unknown subcommand: error: unrecognized subcommand '/etc/openab/config.toml' Fix: CMD ["/etc/openab/config.toml"] → CMD ["run", "/etc/openab/config.toml"] Fixes openabdev#334 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
chaodu-agent
approved these changes
Apr 14, 2026
Collaborator
chaodu-agent
left a comment
There was a problem hiding this comment.
✅ Approved.
Straightforward fix — adds the missing run subcommand to all 5 Dockerfiles after the clap migration in #191. This is the only correct fix; the change is minimal and zero-risk.
Reviewed by 超渡法師 🙏
chengli
pushed a commit
to chengli/openab
that referenced
this pull request
Apr 15, 2026
When max_sessions > 1, each session gets an isolated workspace at
{working_dir}/sessions/{thread_id}. Strategy:
- Try git clone --local first (for git repo working dirs)
- Fallback to mkdir (for PV-mounted dirs without git)
Workspace lifecycle: created on session spawn, cleaned up on
idle timeout and shutdown.
Only patch on top of upstream v0.7.5. Dockerfile CMD fix no longer
needed (upstream fixed in 0.7.5 via PR openabdev#335).
Fork drift: 1 patch.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
dogzzdogzz
added a commit
to dogzzdogzz/openab
that referenced
this pull request
Apr 15, 2026
Resolve conflicts: - format.rs: keep shorten_thread_name (ours), remove truncate_chars (upstream removed it in favor of tail-priority truncation) - adapter.rs: replace truncate_chars with tail-priority truncation (keep last N chars during streaming, matching upstream's approach) - discord.rs: keep our refactored DiscordAdapter version (upstream changes to compose_display/tool collapse are in their monolithic discord.rs which we replaced) - Dockerfiles: upstream merged our openabdev#335 fix + added procps Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
pahud
added a commit
that referenced
this pull request
Apr 15, 2026
CMD now uses 'run' subcommand to match #335 fix applied to other Dockerfiles.
pahud
pushed a commit
to wangyuyan-agent/openab
that referenced
this pull request
Apr 15, 2026
…elm chart - Fix CMD to use 'run' subcommand (matches openabdev#335 fix for other Dockerfiles) - Add opencode variant to build.yml (build-image, merge-manifests, promote-stable) - Add opencode to docker-smoke-test.yml - Add commented-out opencode preset example in Helm values.yaml
pahud
pushed a commit
to wangyuyan-agent/openab
that referenced
this pull request
Apr 15, 2026
…elm chart - Fix CMD to use 'run' subcommand (matches openabdev#335 fix for other Dockerfiles) - Add opencode variant to build.yml (build-image, merge-manifests, promote-stable) - Add opencode to docker-smoke-test.yml - Add commented-out opencode preset example in Helm values.yaml
thepagent
added a commit
to wangyuyan-agent/openab
that referenced
this pull request
Apr 15, 2026
…elm chart - Fix CMD to use 'run' subcommand (matches openabdev#335 fix for other Dockerfiles) - Add opencode variant to build.yml (build-image, merge-manifests, promote-stable) - Add opencode to docker-smoke-test.yml - Add commented-out opencode preset example in Helm values.yaml
thepagent
added a commit
to wangyuyan-agent/openab
that referenced
this pull request
Apr 15, 2026
…elm chart - Fix CMD to use 'run' subcommand (matches openabdev#335 fix for other Dockerfiles) - Add opencode variant to build.yml (build-image, merge-manifests, promote-stable) - Add opencode to docker-smoke-test.yml - Add commented-out opencode preset example in Helm values.yaml
thepagent
added a commit
to wangyuyan-agent/openab
that referenced
this pull request
Apr 15, 2026
…elm chart - Fix CMD to use 'run' subcommand (matches openabdev#335 fix for other Dockerfiles) - Add opencode variant to build.yml (build-image, merge-manifests, promote-stable) - Add opencode to docker-smoke-test.yml - Add commented-out opencode preset example in Helm values.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What problem does this solve?
After #191 added clap CLI with subcommands, all Dockerfiles still pass the config path as a positional argument, breaking every Docker/K8s deployment on v0.7.4+.
Closes #334
At a Glance
Prior Art & Industry Research
OpenClaw: Uses
CMD ["node", "dist/main.js"]— no subcommands, not applicable.Hermes Agent: Uses
CMD ["python", "-m", "hermes_agent"]— no subcommands, not applicable.Neither project uses a Rust clap-style CLI with subcommands in Docker, so there's no prior art to draw from. This is a straightforward Docker CMD compatibility fix.
Proposed Solution
Change
CMDin all 5 Dockerfiles from["/etc/openab/config.toml"]to["run", "/etc/openab/config.toml"].Why this approach?
The only correct fix — the clap CLI requires the
runsubcommand before the config path. No other options.Alternatives Considered
run: Already implemented (unwrap_or(Commands::Run { config: None })), but only works when no arguments are passed. A positional arg is always interpreted as a subcommand name by clap.Validation
cargo checkpassescargo testpasses (40 tests)docker run openab:latestnow starts correctly with/etc/openab/config.toml🤖 Generated with Claude Code